return {
  "rmagatti/auto-session",
  enabled = true,
  config = function()
    local auto_session = require("auto-session")

    vim.o.sessionoptions =
      "blank,buffers,curdir,folds,help,tabpages,winsize,winpos,terminal,localoptions"

    auto_session.setup({
      auto_restore = false,
      suppressed_dirs = {
        "~/",
        "~/Dev/",
        "~/Downloads",
        "~/Documents",
        "~/Desktop/",
      },
    })

    -- restore last workspace session for current directory
    vim.keymap.set(
      "n",
      "<leader>sr",
      "<Cmd>SessionRestore<CR>",
      { noremap = true, silent = true, desc = "Restore session for cwd" }
    )

    -- save workspace session for current working directory
    vim.keymap.set("n", "<leader>ss", "<Cmd>SessionSave<CR>", {
      noremap = true,
      silent = true,
      desc = "Save session for auto session root dir",
    })
  end,
}
